import * as types from '../types'


const initialState = {
    account: '',
    password: ''
}



export default (state = initialState, action) => {
    switch (action.type){
        case types.LOGIN_SUCCESS: 
        let {account, password} = action
        return {
            ...state,
            account,
            password
        }
        default: {
            return state
        }
    }
}